//Source file: D:\\test\\com\\ce\\pms\\house\\model\\Environment.java

package com.ce.pms.house.model;

import javax.persistence.CascadeType;
import javax.persistence.Column;
import javax.persistence.Embedded;
import javax.persistence.Entity;
import javax.persistence.FetchType;
import javax.persistence.GeneratedValue;
import javax.persistence.Id;
import javax.persistence.JoinColumn;
import javax.persistence.ManyToOne;
import javax.persistence.OneToOne;
import javax.persistence.Table;

import com.ce.pms.common.model.SysInfo;
import com.sitechasia.webx.core.model.IDomainObject;


/**
 * 实体:配套设施
 * 关联表：HM_ENVIRONMENT
 */
@Entity
@Table(name = "HM_ENVIRONMENT")
public class Environment implements IDomainObject
{

	/**
	 * 配套设施ID
	 */
	@Id @GeneratedValue @Column(name = "ENVIRONMENT_ID")
	private Long keyword;
	/**
	 * 所属建设期
	 */
	@ManyToOne()
	@JoinColumn(name="PROJECT_ID",nullable=true)
	private ProjectDomain project;
   /**
    * 设施名称
    */
	@Column(name = "NAME",length = 50)
   private String name;

   /**
    * 平面图
    * 检索策略:lazy=false
    */
	@OneToOne(cascade = CascadeType.ALL,fetch = FetchType.LAZY)
	@JoinColumn(name = "ICHNOGRAPHYS_ID")
   private ImageDomain ichnographysImage;

   /**
    * 效果图
    * 检索策略:lazy=false
    */
	@OneToOne(fetch = FetchType.LAZY)
	@JoinColumn(name = "VISION_IMAGE_ID")
   private ImageDomain visionImage;

   /**
    * 描述
    */
   @Column(name = "DESCRIPTION",length = 1000)
   private String description;

   /***
    * 系统信息
    */
   @Embedded
   private SysInfo sysInfo;

   public Environment()
   {

   }

public String getDescription() {
	return description;
}

public void setDescription(String description) {
	this.description = description;
}

public ImageDomain getIchnographysImage() {
	return ichnographysImage;
}

public void setIchnographysImage(ImageDomain ichnographysImage) {
	this.ichnographysImage = ichnographysImage;
}

public String getName() {
	return name;
}

public void setName(String name) {
	this.name = name;
}

public SysInfo getSysInfo() {
	return sysInfo;
}

public void setSysInfo(SysInfo sysInfo) {
	this.sysInfo = sysInfo;
}

public ImageDomain getVisionImage() {
	return visionImage;
}

public void setVisionImage(ImageDomain visionImage) {
	this.visionImage = visionImage;
}

/**
 * @return the keyword
 */
public Long getKeyword() {
	return keyword;
}

/**
 * @param keyword the keyword to set
 */
public void setKeyword(Long keyword) {
	this.keyword = keyword;
}

/**
 * @return the project
 */
public ProjectDomain getProject() {
	return project;
}

/**
 * @param project the project to set
 */
public void setProject(ProjectDomain project) {
	this.project = project;
}


}
